Subject: Re: Stack problems
From: [email-masked] (HANG-FIRE)
To: [email-masked], [email-masked]
Date: Fri, 16 Sep 1994 13:27:42 +0100

> I've had some stack problems too. Strange thing is that I don't use
> recursive procedures at all. I just make a str$(x) - variable to 
> string and then print it out using RI's FNSPrint. Anyway, if
> I call this routine (and it's not procedure or statement - just
> gosub) about 100 times then it say out stack. Comments?? Whats wrong??

Hi,
   the FNSPrint command needs to store a bit of data on the stack.  Eaxctly,
it stores all the registers (I think) onto the stack whilst the command is
running (15*4 bytes = 60 bytes of stack space).  Additionally it also has to
store extra registers *temporarily* if you're using underline.  The data is
restored from the stack quite happily - if it wasn't blitz would go into runtime
error mode with a stack frame error (or something like that).

I can have a try and see if there are any stack related problems with the FNS
commands.  I'm sure though that the problem must lie elsewhere, nevertheless
I'll still have a look through my code to see if it ever aborts without
restoring the stack.

Steve Mc.